/*
    RecipeViewer: An application for viewing recipes
    Copyright (C) 2009  Wade Smith

    This program is free software: you can redistribute it and/or modify
    it under the terms of the GNU General Public License as published by
    the Free Software Foundation, either version 3 of the License, or
    (at your option) any later version.

    This program is distributed in the hope that it will be useful,
    but WITHOUT ANY WARRANTY; without even the implied warranty of
    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
    GNU General Public License for more details.

    You should have received a copy of the GNU General Public License
    along with this program.  If not, see <http://www.gnu.org/licenses/>.
*/

#include <QtGui/QApplication>
#include "viewerwindow.h"

int main(int argc, char *argv[])
{
    QApplication application(argc, argv);
    application.setApplicationName("Recipe Viewer");
    application.setApplicationVersion("0.0.1.8");
    application.setOrganizationName("Woodsbury");

    /*******************************************************************************************************/
    qWarning("TODO: Set proper values for names and version (main.cpp)");
    qWarning("TODO: Set a default window icon (main.cpp)");
    qWarning("TODO: Improve the about dialogue box (viewerwindow.cpp)");
    qWarning("TODO: Work out what's happening with the default style sheet and classes (viewerwindow.cpp)");
    qWarning("TODO: Add 'Open in New Window...' menu item (viewerwindow.cpp)");
    qWarning("TODO: Add 'Export As' menu item with sub-items 'HTML' and 'PDF'");
    qWarning("TODO: Store last selected directory in QSettings (viewerwindow.cpp)");
    qWarning("TODO: Improve various strings and add translate function (viewerwindow.cpp)");
    qWarning("TODO: Add 'Print...' menu option");
    qWarning("TODO: Add recipe title or file name to window title (viewerwindow.cpp)");
    qWarning("TODO: Have 'Save Copy...' dialogue have name of current file to save as (viewerwindow.cpp)");
    /*******************************************************************************************************/

    ViewerWindow *viewerWindow;
    // If a file is given as an argument, pass it to the constructor
    if (argc > 1)
    {
        viewerWindow = new ViewerWindow(argv[1]);
    }
    else
    {
        viewerWindow = new ViewerWindow;
    }
    viewerWindow->show();

    return application.exec();
}
